This forum is closed to new posts and
responses. Individual names altered for privacy purposes. The information contained in this website is provided for informational purposes only and should not be construed as a forum for customer support requests. Any customer support requests should be directed to the official HCL customer support channels below:
I ran into the same problem with required fields on a Xpage form under the Tabbed Panel control. Here's a possible work-around:
First, turn off client-side validation. This is done in the Application Properties, XPages tab.
Next, set a flag on the server to check when you want to validate vs. when you don't.
I used the XPages' BeforePageLoad event and the following code:
sessionScope.validateForm="false";
Next, on the field you want to conditionally require, for the 'Required field' check box compute the value with the following Javascript:
sessionScope.validateForm;
Next, to enable the checking use the following code in your Submit button or some such event - be sure to put it right at the top so the validation happens before the rest:
sessionScope.validateForm="true";
I do whatever server actions I intend, then reset the value to false at the end:
sessionScope.validateForm="false";
I'm sure there is a better way but this is at least one possible solution.
Feedback response number WEBB7NYQTE created by ~Wendy Ekwether on 02/05/2009